package cn.bkrc.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpSession;

@Controller
public class LoginController {

    @RequestMapping("/")
    public String login(){
        return "login";
    }

    @RequestMapping("/dologin")
    public  String doLogin(String uname, String upwd, HttpSession httpSession){
        httpSession.setAttribute("uname",uname);
        return "main";
    }

}
